3.1.28 \(\int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx\) [28]

3.1.28.1 Optimal result
3.1.28.2 Mathematica [A] (verified)
3.1.28.3 Rubi [A] (verified)
3.1.28.4 Maple [A] (verified)
3.1.28.5 Fricas [A] (verification not implemented)
3.1.28.6 Sympy [C] (verification not implemented)
3.1.28.7 Maxima [A] (verification not implemented)
3.1.28.8 Giac [A] (verification not implemented)
3.1.28.9 Mupad [B] (verification not implemented)

3.1.28.1 Optimal result

Integrand size = 12, antiderivative size = 83 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=-\frac {59 x}{2048}-\frac {59 \arctan \left (\frac {\sin (c+d x)}{3-\cos (c+d x)}\right )}{1024 d}-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}-\frac {45 \sin (c+d x)}{512 d (5-3 \cos (c+d x))} \]

output
-59/2048*x-59/1024*arctan(sin(d*x+c)/(3-cos(d*x+c)))/d-3/32*sin(d*x+c)/d/( 
5-3*cos(d*x+c))^2-45/512*sin(d*x+c)/d/(5-3*cos(d*x+c))
 
3.1.28.2 Mathematica [A] (verified)

Time = 0.17 (sec) , antiderivative size = 65, normalized size of antiderivative = 0.78 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=\frac {-59 \arctan \left (2 \tan \left (\frac {1}{2} (c+d x)\right )\right ) (5-3 \cos (c+d x))^2-546 \sin (c+d x)+135 \sin (2 (c+d x))}{1024 d (5-3 \cos (c+d x))^2} \]

input
Integrate[(-5 + 3*Cos[c + d*x])^(-3),x]
 
output
(-59*ArcTan[2*Tan[(c + d*x)/2]]*(5 - 3*Cos[c + d*x])^2 - 546*Sin[c + d*x] 
+ 135*Sin[2*(c + d*x)])/(1024*d*(5 - 3*Cos[c + d*x])^2)
 
3.1.28.3 Rubi [A] (verified)

Time = 0.37 (sec) , antiderivative size = 93, normalized size of antiderivative = 1.12, number of steps used = 7, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.583, Rules used = {3042, 3143, 3042, 3233, 27, 3042, 3136}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {1}{(3 \cos (c+d x)-5)^3} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\left (3 \sin \left (c+d x+\frac {\pi }{2}\right )-5\right )^3}dx\)

\(\Big \downarrow \) 3143

\(\displaystyle -\frac {1}{32} \int \frac {3 \cos (c+d x)+10}{(5-3 \cos (c+d x))^2}dx-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

\(\Big \downarrow \) 3042

\(\displaystyle -\frac {1}{32} \int \frac {3 \sin \left (c+d x+\frac {\pi }{2}\right )+10}{\left (5-3 \sin \left (c+d x+\frac {\pi }{2}\right )\right )^2}dx-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

\(\Big \downarrow \) 3233

\(\displaystyle \frac {1}{32} \left (\frac {1}{16} \int -\frac {59}{5-3 \cos (c+d x)}dx-\frac {45 \sin (c+d x)}{16 d (5-3 \cos (c+d x))}\right )-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{32} \left (-\frac {59}{16} \int \frac {1}{5-3 \cos (c+d x)}dx-\frac {45 \sin (c+d x)}{16 d (5-3 \cos (c+d x))}\right )-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{32} \left (-\frac {59}{16} \int \frac {1}{5-3 \sin \left (c+d x+\frac {\pi }{2}\right )}dx-\frac {45 \sin (c+d x)}{16 d (5-3 \cos (c+d x))}\right )-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

\(\Big \downarrow \) 3136

\(\displaystyle \frac {1}{32} \left (-\frac {59}{16} \left (\frac {\arctan \left (\frac {\sin (c+d x)}{3-\cos (c+d x)}\right )}{2 d}+\frac {x}{4}\right )-\frac {45 \sin (c+d x)}{16 d (5-3 \cos (c+d x))}\right )-\frac {3 \sin (c+d x)}{32 d (5-3 \cos (c+d x))^2}\)

input
Int[(-5 + 3*Cos[c + d*x])^(-3),x]
 
output
(-3*Sin[c + d*x])/(32*d*(5 - 3*Cos[c + d*x])^2) + ((-59*(x/4 + ArcTan[Sin[ 
c + d*x]/(3 - Cos[c + d*x])]/(2*d)))/16 - (45*Sin[c + d*x])/(16*d*(5 - 3*C 
os[c + d*x])))/32
 

3.1.28.3.1 Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3136
Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{q = Rt[ 
a^2 - b^2, 2]}, Simp[x/q, x] + Simp[(2/(d*q))*ArcTan[b*(Cos[c + d*x]/(a + q 
 + b*Sin[c + d*x]))], x]] /; FreeQ[{a, b, c, d}, x] && GtQ[a^2 - b^2, 0] && 
 PosQ[a]
 

rule 3143
Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos 
[c + d*x]*((a + b*Sin[c + d*x])^(n + 1)/(d*(n + 1)*(a^2 - b^2))), x] + Simp 
[1/((n + 1)*(a^2 - b^2))   Int[(a + b*Sin[c + d*x])^(n + 1)*Simp[a*(n + 1) 
- b*(n + 2)*Sin[c + d*x], x], x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[a^2 - 
 b^2, 0] && LtQ[n, -1] && IntegerQ[2*n]
 

rule 3233
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + 
(f_.)*(x_)]), x_Symbol] :> Simp[(-(b*c - a*d))*Cos[e + f*x]*((a + b*Sin[e + 
 f*x])^(m + 1)/(f*(m + 1)*(a^2 - b^2))), x] + Simp[1/((m + 1)*(a^2 - b^2)) 
  Int[(a + b*Sin[e + f*x])^(m + 1)*Simp[(a*c - b*d)*(m + 1) - (b*c - a*d)*( 
m + 2)*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c 
- a*d, 0] && NeQ[a^2 - b^2, 0] && LtQ[m, -1] && IntegerQ[2*m]
 
3.1.28.4 Maple [A] (verified)

Time = 0.79 (sec) , antiderivative size = 64, normalized size of antiderivative = 0.77

method result size
derivativedivides \(\frac {-\frac {4 \left (\frac {51 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{512}+\frac {69 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2048}\right )}{{\left (4 \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+1\right )}^{2}}-\frac {59 \arctan \left (2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{1024}}{d}\) \(64\)
default \(\frac {-\frac {4 \left (\frac {51 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{512}+\frac {69 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2048}\right )}{{\left (4 \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+1\right )}^{2}}-\frac {59 \arctan \left (2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{1024}}{d}\) \(64\)
risch \(-\frac {3 i \left (59 \,{\mathrm e}^{3 i \left (d x +c \right )}-295 \,{\mathrm e}^{2 i \left (d x +c \right )}+241 \,{\mathrm e}^{i \left (d x +c \right )}-45\right )}{256 d \left (3 \,{\mathrm e}^{2 i \left (d x +c \right )}-10 \,{\mathrm e}^{i \left (d x +c \right )}+3\right )^{2}}+\frac {59 i \ln \left ({\mathrm e}^{i \left (d x +c \right )}-\frac {1}{3}\right )}{2048 d}-\frac {59 i \ln \left ({\mathrm e}^{i \left (d x +c \right )}-3\right )}{2048 d}\) \(105\)
parallelrisch \(\frac {59 i \left (-9 \cos \left (2 d x +2 c \right )-59+60 \cos \left (d x +c \right )\right ) \ln \left (2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )-i\right )+59 i \left (59+9 \cos \left (2 d x +2 c \right )-60 \cos \left (d x +c \right )\right ) \ln \left (2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+i\right )+2184 \sin \left (d x +c \right )-540 \sin \left (2 d x +2 c \right )}{2048 d \left (-9 \cos \left (2 d x +2 c \right )-59+60 \cos \left (d x +c \right )\right )}\) \(127\)

input
int(1/(-5+3*cos(d*x+c))^3,x,method=_RETURNVERBOSE)
 
output
1/d*(-4*(51/512*tan(1/2*d*x+1/2*c)^3+69/2048*tan(1/2*d*x+1/2*c))/(4*tan(1/ 
2*d*x+1/2*c)^2+1)^2-59/1024*arctan(2*tan(1/2*d*x+1/2*c)))
 
3.1.28.5 Fricas [A] (verification not implemented)

Time = 0.27 (sec) , antiderivative size = 90, normalized size of antiderivative = 1.08 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=\frac {59 \, {\left (9 \, \cos \left (d x + c\right )^{2} - 30 \, \cos \left (d x + c\right ) + 25\right )} \arctan \left (\frac {5 \, \cos \left (d x + c\right ) - 3}{4 \, \sin \left (d x + c\right )}\right ) + 12 \, {\left (45 \, \cos \left (d x + c\right ) - 91\right )} \sin \left (d x + c\right )}{2048 \, {\left (9 \, d \cos \left (d x + c\right )^{2} - 30 \, d \cos \left (d x + c\right ) + 25 \, d\right )}} \]

input
integrate(1/(-5+3*cos(d*x+c))^3,x, algorithm="fricas")
 
output
1/2048*(59*(9*cos(d*x + c)^2 - 30*cos(d*x + c) + 25)*arctan(1/4*(5*cos(d*x 
 + c) - 3)/sin(d*x + c)) + 12*(45*cos(d*x + c) - 91)*sin(d*x + c))/(9*d*co 
s(d*x + c)^2 - 30*d*cos(d*x + c) + 25*d)
 
3.1.28.6 Sympy [C] (verification not implemented)

Result contains complex when optimal does not.

Time = 1.34 (sec) , antiderivative size = 366, normalized size of antiderivative = 4.41 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=\begin {cases} \frac {x}{\left (-5 + 3 \cosh {\left (2 \operatorname {atanh}{\left (\frac {1}{2} \right )} \right )}\right )^{3}} & \text {for}\: c = - d x - 2 i \operatorname {atanh}{\left (\frac {1}{2} \right )} \vee c = - d x + 2 i \operatorname {atanh}{\left (\frac {1}{2} \right )} \\\frac {x}{\left (3 \cos {\left (c \right )} - 5\right )^{3}} & \text {for}\: d = 0 \\- \frac {944 \left (\operatorname {atan}{\left (2 \tan {\left (\frac {c}{2} + \frac {d x}{2} \right )} \right )} + \pi \left \lfloor {\frac {\frac {c}{2} + \frac {d x}{2} - \frac {\pi }{2}}{\pi }}\right \rfloor \right ) \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )}}{16384 d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 8192 d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 1024 d} - \frac {472 \left (\operatorname {atan}{\left (2 \tan {\left (\frac {c}{2} + \frac {d x}{2} \right )} \right )} + \pi \left \lfloor {\frac {\frac {c}{2} + \frac {d x}{2} - \frac {\pi }{2}}{\pi }}\right \rfloor \right ) \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )}}{16384 d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 8192 d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 1024 d} - \frac {59 \left (\operatorname {atan}{\left (2 \tan {\left (\frac {c}{2} + \frac {d x}{2} \right )} \right )} + \pi \left \lfloor {\frac {\frac {c}{2} + \frac {d x}{2} - \frac {\pi }{2}}{\pi }}\right \rfloor \right )}{16384 d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 8192 d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 1024 d} - \frac {408 \tan ^{3}{\left (\frac {c}{2} + \frac {d x}{2} \right )}}{16384 d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 8192 d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 1024 d} - \frac {138 \tan {\left (\frac {c}{2} + \frac {d x}{2} \right )}}{16384 d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 8192 d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 1024 d} & \text {otherwise} \end {cases} \]

input
integrate(1/(-5+3*cos(d*x+c))**3,x)
 
output
Piecewise((x/(-5 + 3*cosh(2*atanh(1/2)))**3, Eq(c, -d*x - 2*I*atanh(1/2)) 
| Eq(c, -d*x + 2*I*atanh(1/2))), (x/(3*cos(c) - 5)**3, Eq(d, 0)), (-944*(a 
tan(2*tan(c/2 + d*x/2)) + pi*floor((c/2 + d*x/2 - pi/2)/pi))*tan(c/2 + d*x 
/2)**4/(16384*d*tan(c/2 + d*x/2)**4 + 8192*d*tan(c/2 + d*x/2)**2 + 1024*d) 
 - 472*(atan(2*tan(c/2 + d*x/2)) + pi*floor((c/2 + d*x/2 - pi/2)/pi))*tan( 
c/2 + d*x/2)**2/(16384*d*tan(c/2 + d*x/2)**4 + 8192*d*tan(c/2 + d*x/2)**2 
+ 1024*d) - 59*(atan(2*tan(c/2 + d*x/2)) + pi*floor((c/2 + d*x/2 - pi/2)/p 
i))/(16384*d*tan(c/2 + d*x/2)**4 + 8192*d*tan(c/2 + d*x/2)**2 + 1024*d) - 
408*tan(c/2 + d*x/2)**3/(16384*d*tan(c/2 + d*x/2)**4 + 8192*d*tan(c/2 + d* 
x/2)**2 + 1024*d) - 138*tan(c/2 + d*x/2)/(16384*d*tan(c/2 + d*x/2)**4 + 81 
92*d*tan(c/2 + d*x/2)**2 + 1024*d), True))
 
3.1.28.7 Maxima [A] (verification not implemented)

Time = 0.35 (sec) , antiderivative size = 112, normalized size of antiderivative = 1.35 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=-\frac {\frac {6 \, {\left (\frac {23 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {68 \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}}\right )}}{\frac {8 \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {16 \, \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} + 1} + 59 \, \arctan \left (\frac {2 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{1024 \, d} \]

input
integrate(1/(-5+3*cos(d*x+c))^3,x, algorithm="maxima")
 
output
-1/1024*(6*(23*sin(d*x + c)/(cos(d*x + c) + 1) + 68*sin(d*x + c)^3/(cos(d* 
x + c) + 1)^3)/(8*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + 16*sin(d*x + c)^4/ 
(cos(d*x + c) + 1)^4 + 1) + 59*arctan(2*sin(d*x + c)/(cos(d*x + c) + 1)))/ 
d
 
3.1.28.8 Giac [A] (verification not implemented)

Time = 0.27 (sec) , antiderivative size = 77, normalized size of antiderivative = 0.93 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=-\frac {59 \, d x + 59 \, c + \frac {12 \, {\left (68 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 23 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (4 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{2}} - 118 \, \arctan \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) - 3}\right )}{2048 \, d} \]

input
integrate(1/(-5+3*cos(d*x+c))^3,x, algorithm="giac")
 
output
-1/2048*(59*d*x + 59*c + 12*(68*tan(1/2*d*x + 1/2*c)^3 + 23*tan(1/2*d*x + 
1/2*c))/(4*tan(1/2*d*x + 1/2*c)^2 + 1)^2 - 118*arctan(sin(d*x + c)/(cos(d* 
x + c) - 3)))/d
 
3.1.28.9 Mupad [B] (verification not implemented)

Time = 14.40 (sec) , antiderivative size = 96, normalized size of antiderivative = 1.16 \[ \int \frac {1}{(-5+3 \cos (c+d x))^3} \, dx=\frac {59\,\left (\mathrm {atan}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )-\frac {d\,x}{2}\right )}{1024\,d}-\frac {59\,\mathrm {atan}\left (2\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{1024\,d}-\frac {\frac {51\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{2048}+\frac {69\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{8192}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{2}+\frac {1}{16}\right )} \]

input
int(1/(3*cos(c + d*x) - 5)^3,x)
 
output
(59*(atan(tan(c/2 + (d*x)/2)) - (d*x)/2))/(1024*d) - (59*atan(2*tan(c/2 + 
(d*x)/2)))/(1024*d) - ((69*tan(c/2 + (d*x)/2))/8192 + (51*tan(c/2 + (d*x)/ 
2)^3)/2048)/(d*(tan(c/2 + (d*x)/2)^2/2 + tan(c/2 + (d*x)/2)^4 + 1/16))